#!/bin/bash

function _locate()
{
    INC_DIR=`dirname $0`"/../"
    [ -d "$INC_DIR" ] && find "$INC_DIR" -name "$1" | head -n 1
}

function _include()
{
    INC_FILE=`_locate "$1"`
    [ -f "$INC_FILE" ] && . "$INC_FILE" && echo "#include $INC_FILE"
}

if [ "$SEA_DBG" != "" ]
then

INCLUDE=`dirname $0`/include.sh
[ ! -f "$INCLUDE" ] && echo "Could not find $INCLUDE" && exit 1
. $INCLUDE

fi

#_include $1
#_locate $1

